package com.fantabest.common.client.model;

import com.extjs.gxt.ui.client.Registry;
import com.extjs.gxt.ui.client.data.BaseTreeModel;
import com.fantabest.common.client.AppEvents;
import com.fantabest.common.client.FantaBestConstants;
import com.fantabest.common.client.RegistryKeys;

public class MenuFactory {

	private static FantaBestConstants constants = Registry.get(RegistryKeys.CONSTANTS);
	
	public static BaseTreeModel getImportMenu()	{
		BaseTreeModel menu = new BaseTreeModel();
		menu.add(new MenuChildData(constants.importPlayers(), AppEvents.MenuImportPlayers));
		return menu;
	}
	
	public static BaseTreeModel getManagementMenu()	{
		BaseTreeModel menu = new BaseTreeModel();
		menu.add(new MenuChildData(constants.seasonsManagement(), AppEvents.MenuManageSeason));
		return menu;
	}
	
	public static BaseTreeModel getAppManagementMenu()	{
		BaseTreeModel menu = new BaseTreeModel();
		menu.add(new MenuChildData(constants.market(), AppEvents.MenuMarket));
		menu.add(new MenuChildData(constants.squad(), AppEvents.MenuSquad));
		return menu;
	}	

}
